package top.xcxdl.rural;

import org.junit.Test;
import org.springframework.boot.test.context.SpringBootTest;
import top.xcxdl.rural.utils.UrlUtils;

import java.util.HashMap;
import java.util.Map;

/**
 * Created by IntelliJ IDEA.
 *
 * @Author : Ding
 * @create 2022/6/15 12:01
 */
@SpringBootTest
public class test {
    @Test
    public void sendGetNoParam(){
        System.err.println(UrlUtils.sendGet("https://geo.datav.aliyun.com/areas_v3/bound/geojson?code=150000_full"));
    }

    @Test
    public void sendGetWithParam(){
        System.err.println(UrlUtils.sendGet("http://47.93.20.178:8881/user/getProductList",new HashMap<String,Object>(2){{
            put("page_no",1);
            put("page_size",10);
        }}));
    }
}
